
//
//  AllViewCell.m
//  XiangMuB
//
//  Created by 999999999999 on 16/8/17.
//  Copyright © 2016年 lanou3g. All rights reserved.
//

#import "AllViewCell.h"
#import "AllModel.h"
#import <UIImageView+WebCache.h>
@implementation AllViewCell

-(void)awakeFromNib {
    //cell的背景图片
    UIImageView *bgView = [[UIImageView alloc]init];
    bgView.image = [UIImage imageNamed:@"mainCellBackground"];
    self.backgroundView = bgView;
}
-(void)setFrame:(CGRect)frame {
    frame.origin.x = 10;
    frame.size.width -= 2*frame.origin.x;
    frame.size.height -= 6;
    frame.origin.y += 10;
    [super setFrame:frame];
}
-(void)setModel:(AllModel *)model {
    _model = model;
    self.title.text = model.title;
    [self.iconImage sd_setImageWithURL:[NSURL URLWithString:model.imgsrc] completed:nil];
    self.sources.text = model.source;
}
@end
